import android.util.Base64;
import java.io.PrintStream;
import javax.crypto.Cipher;
import javax.crypto.spec.SecretKeySpec;

public class AESUtils
{
  private static final String CipherMode = "AES/ECB/PKCS7Padding";

  public static String Decrypt(String paramString)
    throws Exception
  {
    try
    {
      SecretKeySpec localSecretKeySpec = new SecretKeySpec("AdcrR4goRY8lODsg".getBytes("UTF-8"), "AES");
      Cipher localCipher = Cipher.getInstance("AES/ECB/PKCS7Padding");
      localCipher.init(2, localSecretKeySpec);
      byte[] arrayOfByte = Base64.decode(paramString, 0);
      try
      {
        str = new String(localCipher.doFinal(arrayOfByte));
        return str;
      }
      catch (Exception localException2)
      {
        while (true)
        {
          System.out.println(localException2.toString());
          str = null;
        }
      }
    }
    catch (Exception localException1)
    {
      while (true)
      {
        System.out.println(localException1.toString());
        String str = null;
      }
    }
    finally
    {
    }
  }

  public static String Encrypt(String paramString)
    throws Exception
  {
    SecretKeySpec localSecretKeySpec = new SecretKeySpec("AdcrR4goRY8lODsg".getBytes(), "AES");
    Cipher localCipher = Cipher.getInstance("AES/ECB/PKCS7Padding");
    localCipher.init(1, localSecretKeySpec);
    return new String(Base64.encode(localCipher.doFinal(paramString.getBytes()), 0));
  }
}